/**
 * 
 */
package br.com.rafael.gestorinvestimentos.tests;

import java.util.Date;
import java.util.GregorianCalendar;

/**
 * @author Rafael Sperendio
 *
 */
public class Teste {
	public Teste(){
		GregorianCalendar cal1 = new GregorianCalendar();
		Date date = new Date(System.currentTimeMillis());
		System.out.println(date.getTime());
		cal1.setTime(date);
		
		
	     try{  
             Thread.sleep(300);  
         }  
         catch(InterruptedException e){  
             e.printStackTrace();  
         }  
		
		GregorianCalendar cal2 = new GregorianCalendar();
		date = new Date(System.currentTimeMillis());
		System.out.println(date.getTime());
		cal2.setTime(date);
		
		
		System.out.println(cal1.get(cal1.YEAR));
	}
	
	public static void main(String args[]){
		new Teste();
	}
}
